/*
 Navicat Premium Data Transfer

 Source Server         : local
 Source Server Type    : MySQL
 Source Server Version : 80020
 Source Host           : localhost:3306
 Source Schema         : rn_demo1

 Target Server Type    : MySQL
 Target Server Version : 80020
 File Encoding         : 65001

 Date: 20/11/2020 16:08:15
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for goods
-- ----------------------------
DROP TABLE IF EXISTS `goods`;
CREATE TABLE `goods` (
  `id` int NOT NULL AUTO_INCREMENT,
  `name` varchar(255) NOT NULL,
  `url` varchar(255) NOT NULL,
  `typeId` int NOT NULL,
  `price` int NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

-- ----------------------------
-- Records of goods
-- ----------------------------
BEGIN;
INSERT INTO `goods` VALUES (1, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 1, 1);
INSERT INTO `goods` VALUES (2, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 1, 2);
INSERT INTO `goods` VALUES (3, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 1, 3);
INSERT INTO `goods` VALUES (4, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 1, 4);
INSERT INTO `goods` VALUES (5, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 2, 4);
INSERT INTO `goods` VALUES (6, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 2, 1);
INSERT INTO `goods` VALUES (7, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 2, 3);
INSERT INTO `goods` VALUES (8, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 3, 3);
INSERT INTO `goods` VALUES (9, 'Pizza', 'https://reactnative.dev/img/tiny_logo.png', 3, 4);
COMMIT;

-- ----------------------------
-- Table structure for goodsType
-- ----------------------------
DROP TABLE IF EXISTS `goodsType`;
CREATE TABLE `goodsType` (
  `name` varchar(255) NOT NULL,
  `id` int NOT NULL AUTO_INCREMENT,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

-- ----------------------------
-- Records of goodsType
-- ----------------------------
BEGIN;
INSERT INTO `goodsType` VALUES ('New', 1);
INSERT INTO `goodsType` VALUES ('Rice Noodles', 2);
INSERT INTO `goodsType` VALUES ('Bubble Tea', 3);
COMMIT;

-- ----------------------------
-- Table structure for sku
-- ----------------------------
DROP TABLE IF EXISTS `sku`;
CREATE TABLE `sku` (
  `name` varchar(255) NOT NULL,
  `skuTypeId` int NOT NULL,
  `id` int NOT NULL AUTO_INCREMENT,
  `price` int NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

-- ----------------------------
-- Records of sku
-- ----------------------------
BEGIN;
INSERT INTO `sku` VALUES ('不辣', 1, 1, 0);
INSERT INTO `sku` VALUES ('微辣', 1, 2, 0);
INSERT INTO `sku` VALUES ('特辣', 1, 3, 0);
INSERT INTO `sku` VALUES ('加蛋', 2, 4, 1);
INSERT INTO `sku` VALUES ('加肠', 2, 5, 2);
INSERT INTO `sku` VALUES ('加青菜', 2, 6, 10);
INSERT INTO `sku` VALUES ('加面', 2, 7, 3);
INSERT INTO `sku` VALUES ('苹果', 3, 8, 1);
INSERT INTO `sku` VALUES ('香蕉', 3, 9, 1);
INSERT INTO `sku` VALUES ('火龙果', 3, 10, 5);
INSERT INTO `sku` VALUES ('西红柿', 3, 11, 2);
INSERT INTO `sku` VALUES ('梨', 3, 12, 10);
COMMIT;

-- ----------------------------
-- Table structure for skuType
-- ----------------------------
DROP TABLE IF EXISTS `skuType`;
CREATE TABLE `skuType` (
  `name` varchar(255) NOT NULL,
  `id` int NOT NULL AUTO_INCREMENT,
  `goodsId` int NOT NULL,
  `maximum` int NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;

-- ----------------------------
-- Records of skuType
-- ----------------------------
BEGIN;
INSERT INTO `skuType` VALUES ('口味', 1, 3, 1);
INSERT INTO `skuType` VALUES ('配料', 2, 3, 3);
INSERT INTO `skuType` VALUES ('水果', 3, 3, 4);
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
